package com.school.service;

import java.util.List;
import java.util.Map;

import javax.servlet.ServletContext;

import com.school.entity.HljtDevice;
import com.school.entity.web.HljtDeviceManagement;

public interface HljtDeviceService {
	/**
	 * 判断设备是否注册根据设备的Mac判断
	 * @param hljtDevice
	 * @return
	 */
	HljtDevice equipmentRegistration(HljtDevice hljtDevice);
	/**
	 * 添加设备
	 * @param hljtDevice
	 * @return
	 */
	int addDevice(HljtDevice hljtDevice);
	
	/**
	 * 修改设备表最后请求时间 和皮肤
	 * @param hljtDevice
	 * @return
	 */
	public int updateDevice(HljtDevice hljtDevice);
	

/**
	 * 通过Mac查找一个设备信息
	 * @param Mac
	 * @return
	 */
	public Map<String, Object> findDeviceEX(String versionCode,String versionname ,String mac) throws Exception ;
	
	/**
	 * 修改设备版本信息
	 * @param hljtDevice
	 * @return
	 */
	public Integer updateDeviceUrl(HljtDevice hljtDevice);
	
	/**
	 * 设备解除班级绑定
	 * @param hljtDevice
	 * @return
	 */
	Integer updateDeviceByMavAndClassId(HljtDevice hljtDevice);
	
	
	/***
	 * 没有绑定班级的设备
	 * @return
	 */
	Map<String, Object> deviceNotBoundClass();
	/***
	 * 设备绑定了班级的信息
	 * @return
	 */
	Map<String , Object> deviceBindClassInfo(HljtDeviceManagement hljtDeviceManagement);
	
	/***
	 * 修改设备信息
	 * @return
	 */
	Integer updateDeviceByMac(List<HljtDeviceManagement> hljtDeviceManagement );
	
	
	/***
	 * 添加模式信息
	 * @return
	 */
	boolean addDevicetask(List<HljtDeviceManagement> list);
	
	/***
	 * 所有设备手动开机时间
	 * @return
	 */
	HljtDevice allDeviceMacManualStarupTime(String mac);
	
	/***
	 * 修改设备状态
	 * @return
	 */
	Integer updateDeviceStateByEndTime();
	
	/**
	 * 通过Mac查找一个设备信息
	 * @param Mac
	 * @return
	 */
	public HljtDevice findDevice(String Mac);
}
